#include "PCH.h"
#include "OutputMergeStage.h"
using namespace DeviousRenderer;

OutputMergeStage::OutputMergeStage()
{

}

OutputMergeStage::~OutputMergeStage()
{

}

void OutputMergeStage::SetBlendState(int state)
{
	m_iBlendState = state;
}

void OutputMergeStage::SetDepthStencilState(int state, unsigned int stencilRef /* = 0 */)
{
	m_iDepthStencilState = state;
	m_uiStencilRef = stencilRef;
}

void OutputMergeStage::SetRenderTarget(unsigned int slot, int rtv)
{
	if (slot < D3D11_SIMULTANEOUS_RENDER_TARGET_COUNT)
	{
		m_iRenderTargetViews[i] = rtv;
	}
}

void OutputMergeStage::SetDepthStencilTarget(int dsv)
{
	m_iDepthTargetView = dsv;
}

void OutputMergeStage::SetUnorderredAccessView(unsigned int slot, int uav, unsigned int initCount /* = -1 */)
{
	if (slot < D3D11_PS_CS_UAV_REGISTER_COUNT)
	{
		m_iUnorderedAccessViews[slot] = uav;
		m_uiUAVInitialCounts[slot] = initCount;
	}
}